home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / gs24src.zip / GSTYPE1.H < prev    next >
C/C++ Source or Header  |  1992-03-21  |  2KB  |  52 lines

  1. /* Copyright (C) 1990, 1991 Aladdin Enterprises.  All rights reserved.
  2.    Distributed by Free Software Foundation, Inc.
  3.  
  4. This file is part of Ghostscript.
  5.  
  6. Ghostscript is distributed in the hope that it will be useful, but
  7. WITHOUT ANY WARRANTY.  No author or distributor accepts responsibility
  8. to anyone for the consequences of using it or for whether it serves any
  9. particular purpose or works at all, unless he says so in writing.  Refer
  10. to the Ghostscript General Public License for full details.
  11.  
  12. Everyone is granted permission to copy, modify and redistribute
  13. Ghostscript, but only under the conditions described in the Ghostscript
  14. General Public License.  A copy of this license is supposed to have been
  15. given to you along with Ghostscript so you can know your rights and
  16. responsibilities.  It should be in a file named COPYING.  Among other
  17. things, the copyright notice and this notice must be preserved on all
  18. copies.  */
  19.  
  20. /* gstype1.h */
  21. /* Client interface to Adobe Type 1 font routines for Ghostscript library */
  22.  
  23. /* Encrypt/decrypt procedures */
  24. typedef ushort crypt_state;
  25. #define crypt_charstring_seed 4330
  26. int gs_type1_encrypt(P4(byte *dest, byte *src, uint len, crypt_state *pstate));
  27. int gs_type1_decrypt(P4(byte *dest, byte *src, uint len, crypt_state *pstate));
  28.  
  29. /* CharString interpreter */
  30. typedef struct gs_type1_state_s gs_type1_state;
  31. extern const uint gs_type1_state_sizeof;
  32. #ifndef gs_show_enum_s_DEFINED
  33. struct gs_show_enum_s;
  34. #endif
  35. #ifndef gs_type1_data_s_DEFINED
  36. struct gs_type1_data_s;
  37. #endif
  38. int gs_type1_init(P5(gs_type1_state *pis, struct gs_show_enum_s *penum,
  39.           int charpath_flag, int paint_type,
  40.           struct gs_type1_data_s *pdata));
  41. /* Continue interpreting a Type 1 CharString. */
  42. /* If str != 0, it is taken as the byte string to interpret. */
  43. /* Return 0 on successful completion, <0 on error, */
  44. /* or >0 when client intervention is required. */
  45. /* The int * argument is where the character is stored for seac, */
  46. /* or the othersubr # for callothersubr. */
  47. #define type1_result_seac 1
  48. #define type1_result_callothersubr 2
  49. int gs_type1_interpret(P3(gs_type1_state *, byte *, int *));
  50. /* Pop a (fixed) number off the internal stack */
  51. int gs_type1_pop(P2(gs_type1_state *, fixed *));
  52.